package com.consumerService.module.controller;

import com.consumerService.module.service.TestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.HashMap;
import java.util.Map;

@RestController
@RequestMapping("/test")
public class TestController {

    @Autowired
    private TestService testService;

    @GetMapping("/getMapInfo/{id}")
    public Map<String,Object> getMapInfo(@PathVariable("id") Integer id) {
        return testService.getMapInfo(id);
    }

    @PostMapping("/postMapInfo")
    public Map<String,Object> postMapInfo() {
        Map<String,Object> map = new HashMap<>();
        return testService.postMapInfo(map);
    }
}
